﻿<interactionRequest:InteractionDialogBase 
    xmlns:interactionRequest="clr-namespace:Acme.Prism.InteractionRequest"
    xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"  
    xmlns:ei="http://schemas.microsoft.com/expression/2010/interactions"
    x:Class="Acme.Prism.InteractionRequest.NotificationLocalModalInteractionDialog"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
    mc:Ignorable="d" 
    d:DesignHeight="300" d:DesignWidth="300">
    <Grid Background="#A9CECECE">
        
        <Border Background="White" VerticalAlignment="Center" HorizontalAlignment="Center" MaxWidth="400" MinHeight="150" MinWidth="250">
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="25" />
                    <RowDefinition Height="*" />
                    <RowDefinition Height="40" />
                </Grid.RowDefinitions>
                <Rectangle Stroke="Black" StrokeThickness="1" Margin="0" Grid.RowSpan="3">
                    <Rectangle.Effect>
                        <DropShadowEffect ShadowDepth="0" BlurRadius="20" RenderingBias="Quality" Direction="0" />
                    </Rectangle.Effect>
                </Rectangle>
                
                <Rectangle Fill="#FFA7C1DC" Margin="1,1,1,0" />
                <TextBlock Margin="6,0" Text="{Binding Path=Title}" VerticalAlignment="Center" TextTrimming="CharacterEllipsis" FontSize="16" />

                <ContentControl HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Grid.Row="1" Margin="6"
                        ContentTemplate="{Binding Path=MessageTemplate, RelativeSource={RelativeSource FindAncestor, AncestorType=interactionRequest:InteractionDialogBase, AncestorLevel=1}}"
                        Content="{Binding Path=Content}" />

                <Rectangle Fill="#FFF1F1F1" Margin="1,0,1,1" Grid.Row="2" />

                <Button Content="OK" Width="75" Height="23" HorizontalAlignment="Right" Grid.Row="2" Margin="11,0">
                    <i:Interaction.Triggers>
                        <i:EventTrigger EventName="Click">
                            <ei:CallMethodAction TargetObject="{Binding RelativeSource={RelativeSource FindAncestor, AncestorType=interactionRequest:InteractionDialogBase, AncestorLevel=1}}" MethodName="Close"/>
                        </i:EventTrigger>
                    </i:Interaction.Triggers>
                </Button>
            </Grid>
        </Border>
    </Grid>
</interactionRequest:InteractionDialogBase>
